package com.test.shopping.controller;

import com.test.shopping.pojo.List;
import com.test.shopping.service.listService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RestController;

import java.util.ArrayList;

@RestController
public class listController {
    @Autowired
    private listService listService;
    //用户金额变动明细
    @GetMapping("getUserList/{uId}")
    public ArrayList<List> getUserList(@PathVariable Integer uId){
        List list = new List();
        list.setUId(uId);
        ArrayList<List>  userList = listService.getUserList(uId);
         return userList;
    }
}
